Salt and Survival: Iodized Salt and Life Expectancy Globally

Introduction.

Iodine deficiency is still one of the top preventable causes of intellectual disability and impaired health around the world. The World Health Organization (WHO) and UNICEF have recognized universal salt iodization as a cheap solution to resolve this problem for some time. But how effective has it been?

This report provides a comprehensive analysis of the relationship between iodized salt consumption, sanitation access, life expectancy, and economic factors worldwide. By visualizing trends over time and comparing country-level data, it highlights how public health initiatives, infrastructure, and economic growth influence overall well-being. The data reveals global disparities, with some nations excelling in sanitation and nutrition programs while others struggle due to policy gaps and resource limitations. The insights emphasize the importance of fortification programs, clean water access, and economic development in improving public health outcomes. Understanding these connections can drive effective policymaking and targeted interventions to enhance global health standards.

Global Mapping of Access to Sanitation

This global map displays access to sanitation facilities by country and is representing 2022 data. Darker red shading represents *lower levels of access, and paler yellow represents higher levels of access.

Code
import geopandas as gpd
import polars as pl
import pandas as pd
import matplotlib.pyplot as plt
from IPython.display import display

tableau_data = pl.read_csv("/content/tableau.csv")

# Load world boundaries shapefile from the provided URL
world = gpd.read_file("https://public.opendatasoft.com/api/explore/v2.1/catalog/datasets/world-administrative-boundaries/exports/shp")

# Prepare data (Sanitation Access by Country)
df = (
    tableau_data
    .filter(pl.col("Sanitation_Access(%)").is_not_null())
    .select(["year", "alpha_3_code", "Sanitation_Access(%)"])  # Using the alpha_3_code directly
    .rename({"Sanitation_Access(%)": "sanitation"})
    .to_pandas()
)

# Filter the data for the year 2022
df_2022 = df[df["year"] == 2022]

# Merge the world shapefile data with sanitation access data using the alpha_3_code
merged = world.merge(df_2022, how="left", left_on="iso3", right_on="alpha_3_code")

# Plot the map for 2022
fig, ax = plt.subplots(1, 1, figsize=(15, 8))

# Plot the map with a color gradient for sanitation access and the legend
merged.plot(column='sanitation',
            cmap='YlOrRd',  # Color map for visualization
            linewidth=0.8,
            ax=ax,
            edgecolor='0.8',
            missing_kwds={"color": "lightgrey", "label": "No data"},
            legend=True,
            legend_kwds={
                'label': "Sanitation Access (%)",
                'orientation': 'horizontal',
                'fraction': 0.02,
                'pad': 0.04
            })

ax.set_title("Access to Sanitation Facilities by Country (2022)", fontsize=15)
ax.axis('off')  # Turn off the axis for better visualization

plt.show()

The global story regarding access to sanitation is compelling evidence of inequality in access to basic hygiene:

  • South Sudan, Venezuela, Guinea, and Yemen are few examples of countries showing *alarmingly low access to sanitation, often at levels below 40%.
  • In many of Western Europe, North America, and some parts of East Asia, high sanitation coverage shows the result of investment and political will to improve public health sanitation infrastructure.

  • Sanitation is not just a luxury, but a life-saving (missing goods) public good.
  • The gray areas signify areas of missing, or out of date information, which represents another problem in the sanitation sector; data gaps limit the ability to make value adding interventions.

Closing the access gap for sanitation is foundational to disease prevention, child health, and a person’s dignity regardless of their location in the world.

Code
import polars as pl
import pandas as pd
from plotnine import *
from IPython.display import display
import random

def generate_color_map(countries):
    color_map = {}
    used_colors = set()
    for country in countries:
        while True:
            color = "#{:06x}".format(random.randint(0, 0xFFFFFF))
            if color not in used_colors:
                used_colors.add(color)
                color_map[country] = color
                break
    return color_map

from_year = 1994
to_year = 2022

data = tableau_data.filter(
    (pl.col("year") >= from_year) & (pl.col("year") <= to_year) &
    (pl.col("Iodized_Salt_Consumption(%)").is_not_null())
).rename({"Iodized_Salt_Consumption(%)": "iodine"})

grouped = data.group_by("country").agg([pl.col("iodine").mean().alias("avg_iodine")])

df = grouped.sort("avg_iodine", descending=True).head(10).to_pandas()

if df.empty:
    print("No data available for this selection.")
else:
    color_map = generate_color_map(df["country"].tolist())

    plot = (
        ggplot(df, aes(x='reorder(country, -avg_iodine)', y='avg_iodine', fill='country')) +
        geom_col() +
        geom_text(
            aes(label='round(avg_iodine, 1)'),
            ha='right',
            nudge_y=-2,
            size=10
        ) +
        scale_fill_manual(values=color_map) +
        coord_flip() +
        labs(
            title=f"Top 10 Countries by Iodized Salt Consumption ({from_year}-{to_year})",
            x="Country", y="Average Iodized Salt Consumption (%)"
        ) +
        theme_minimal() +
        theme(figure_size=(9, 6))
    )

    display(plot)

This bar graph outlines the top 10 countries with the highest average consumption of iodized salt from 1994 to 2022.

Each country on the list, from Georgia (100%) to Samoa (98.2%) have made Universal salt iodization an achievable reality everywhere.

some additional heroes are - Georgia with 100% coverage-the gold standard of nutrition-based policy - Qatar, Kenya, and Rwanda are all over 99% - Papua New Guinea, Bhutan, and, many of the high utilizers under specific commentary,